import request from "@/utils/request";

// 查询质检方案列表
export function listQcscheme(query) {
  return request({
    url: "/mes/qc/qcscheme/list",
    method: "get",
    params: query,
  });
}

// 查询质检方案详细
export function getQcscheme(id) {
  return request({
    url: "/mes/qc/qcscheme/" + id,
    method: "get",
  });
}

// 新增质检方案
export function addQcscheme(data) {
  return request({
    url: "/mes/qc/qcscheme",
    method: "post",
    data: data,
  });
}

// 修改质检方案
export function updateQcscheme(data) {
  return request({
    url: "/mes/qc/qcscheme",
    method: "put",
    data: data,
  });
}

// 删除质检方案
export function delQcscheme(id) {
  return request({
    url: "/mes/qc/qcscheme/" + id,
    method: "delete",
  });
}
export function synchronousHead(query) {
  return request({
    url: "/mes/k3cloud/api/quality/syncQcschemeList",
    method: "get",
    params: query,
  });
}

export function synchronousLine(query) {
  return request({
    url: "/mes/k3cloud/api/quality/syncQcschemeentryList",
    method: "get",
    params: query,
  });
}

export function synchronousRange(query) {
  return request({
    url: "/mes/k3cloud/api/quality/syncQcschemescopeList",
    method: "get",
    params: query,
  });
}

export function qcQmQcschemeentrySync(query) {
  return request({
    url: "/sync/k3cloud/api/qcQmQcschemeentrySync/qcQmQcschemeentrySync",
    method: "get",
    params: query,
  });
}
